﻿using Microsoft.SqlServer.Management.Smo;
using System;

namespace JsonToSql
{
    /// <summary>
    /// Column detected by parsing process 
    /// </summary>
    public class JsonColumn
    {
        /// <summary>
        /// Name of column
        /// </summary>
        public string Name
        {
            get;
            set;
        }
        /// <summary>
        /// True column is part of primary keys
        /// </summary>
        public bool PrimaryKey
        {
            get;
            set;
        }
        /// <summary>
        /// Value type detected by parsing cells
        /// </summary>
        public Type ValueType
        {
            get;
            set;
        }
        /// <summary>
        /// Data type detected by parsing cells
        /// </summary>
        public SqlDataType DataType
        {
            get;
            set;
        }
        /// <summary>
        /// Macimum length detected by barsing cells
        /// </summary>
        public int? MaxLength
        {
            get;
            set;
        }

    }
}
